﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="RegisterSqlCacheDependency.aspx.cs" Inherits="Hxsoft.AppV1.Admin.CacheManage.RegisterSqlCacheDependency" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
	<title>注册 SQL 缓存依赖</title>
</head>
<body>
	<form id="form1" runat="server">
		<asp:ScriptManager ID="ScriptManager1" runat="server">
			</asp:ScriptManager>
		<asp:UpdatePanel ID="UpdatePanel1" runat="server">
			<ContentTemplate>
		<div>
			<asp:Button ID="BtnEnableSqlCacheDependency" runat="server" Text="启用 SqlCacheDependency 更改通知" OnClick="BtnEnableSqlCacheDependency_Click" />
			<asp:Button ID="BtnDisableSqlCacheDependency" runat="server" Text="禁用 SqlCacheDependency 更改通知" OnClick="BtnDisableSqlCacheDependency_Click" />
			<br />
			表名:<asp:TextBox ID="TbTableName" runat="server"></asp:TextBox>
			<asp:Button ID="BtnEnableTableForNotifications" runat="server" Text="启用该表的 SqlCacheDependency 更改通知" OnClick="BtnEnableTableForNotifications_Click" />
			<asp:Repeater ID="ListTablesEnabledForNotifications" runat="server" OnItemCommand="ListTablesEnabledForNotifications_ItemCommand">
				<HeaderTemplate>
					<table>
						<tr>
							<td>
								<strong>已经注册缓存通知的表</strong>
							</td>
							<td>
								<strong>取消通知</strong>
							</td>
						</tr>
				</HeaderTemplate>
				<ItemTemplate>
					<tr>
						<td><asp:label ID="LbTableName" Text="<%# Container.DataItem %>" runat="server"></asp:label></td>
						<td><asp:LinkButton ID="LbtDisableTableForNotifications" CommandName="DisableTableForNotifications" runat="server">取消通知</asp:LinkButton></td>
					</tr>
				</ItemTemplate>
				<FooterTemplate>
					</table>
				</FooterTemplate>
			</asp:Repeater>
		</div>
			</ContentTemplate>
		</asp:UpdatePanel>
		<Hxctr:MessageBox ID="MessageBox1" runat="server" />
		<Hxctr:UpdateProgress ID="UpdateProgress1" runat="server" />
	</form>
</body>
</html>